import request from '@/utils/request'

export function queryUnitAuditPage(query) {
  return request({
    url: '/agencySalaryController/queryUnitAuditPage',
    method: 'get',
    params: query
  })
}
export function queryFinancialAuditSalaryPage(query) {
  return request({
    url: '/agencySalaryController/queryFinancialAuditSalaryPage',
    method: 'get',
    params: query
  })
}

export function audit(data) {
  return request({
    url: '/agencySalaryController/auditUnitAudit',
    method: 'post',
    data
  })
}

export function auditMiddle(data) {
  return request({
    url: '/agencySalaryController/auditUnitAuditMiddle',
    method: 'post',
    data
  })
}

export function rejectAudit(data) {
  return request({
    url: '/agencySalaryController/rejectAuditUnitAudit',
    method: 'post',
    data
  })
}
export function rejectAuditMiddle(data) {
  return request({
    url: '/agencySalaryController/rejectAuditUnitAuditMiddle',
    method: 'post',
    data
  })
}

export function returned(data) {
  return request({
    url: '/agencySalaryController/returnedUnitAudit',
    method: 'post',
    data
  })
}

export function rejectReturned(agencyId) {
  return request({
    url: '/agencySalaryController/rejectReturnedUnitAudit/' + agencyId,
    method: 'post'
  })
}

export function queryReturnedState(agencyId) {
  return request({
    url: '/agencySalaryController/queryReturnedState',
    method: 'get',
    params: {
      agencyId
    }
  })
}

export function queryOnePersonInfo(personId) {
  return request({
    url: '/personInfoController/queryOnePersonInfo',
    method: 'get',
    params: {
      personId
    }
  })
}

export function batchAudit(data) {
  return request({
    url: '/agencySalaryController/batchAuditUnitAudit',
    method: 'post',
    data
  })
}

